package at.fhj.antesk.steamvaluecalc.interfaces;

import java.util.List;

import at.fhj.antesk.steamvaluecalc.data.Game;


public interface DataHandler {

    /**
     * Retrieves a list of all games stored in the data source.
     * 
     * @return
     */
    List<Game> loadGames();

    /**
     * Stores a game permanently to the data source. Synchronization deeply recommended!
     * 
     * @param game
     */
    void addGame(Game game);

    /**
     * Stores a list of games permanently to the data source. Synchronization deeply recommended!
     * 
     * @param games
     */
    void storeGames(List<Game> games);

    /**
     * Updates an existing game in the data source if the game exists. TODO throw exception
     * 
     * @param game
     */
    void updateGame(Game game);

    /**
     * Update a existing games in the data source
     * 
     * @param gamesToUpdate
     */
    void updateGamesInFile(List<Game> gamesToUpdate);

}
